exports.init = function(app) {
  // 学校详情
  app.get('/net/schooladmin/school/get', function(req, res) {
    res.send({
      "errcode": "0",
      "errmsg": "ok",
      "data": {
        "id": 1,
        "merchantId": 1,
        "schoolName": "阳光幼儿园",
        "schoolLogo": "https://imgcache.vikduo.com/oss/b7d7df2696132e90729f3f616f967b3c.jpg",
        "schoolAddress": "测试地址",
        "latitude": "11.11",
        "longitude": "22.22",
        "precisions": "11",
        "created": 1507773536,
        "modified": 1507876452,
        "deleted": 0
      }
    })
  })
  // 班级详情
  app.get('/net/schooladmin/school-class/get', function(req, res) {
    res.send({
      "errcode": "0",
      "errmsg": "ok",
      "data": {
        "id": 1,
        "merchantId": 1,
        "schoolId": 1,
        "name": "一班",
        "gradeYear": 2017,
        "graduateYear": 2019,
        "created": 1507881715,
        "modified": 1508120631,
        "deleted": 0
      }
    })
  })
  // 添加班级
  app.post('/net/schooladmin/school-class/create', function(req, res) {
    res.send({
      "errcode": "0",
      "errmsg": "ok",
      "data": {
        "deleted": "0",
        "id": 6,
        "schoolId": 1,
        "name": "class2xx",
        "gradeYear": 1472659200,
        "graduateYear": 1561910400,
        "merchantId": 1,
        "created": 1508479233,
        "modified": 1508479233
      }
    })
  })
  // 编辑班级
  app.post('/net/schooladmin/school-class/update', function(req, res) {
    res.send({
      "errcode": "0",
      "errmsg": "ok",
      "data": [
        1
      ]
    })
  })
  // 删除班级
  app.post('/net/schooladmin/school-class/del', function(req, res) {
    res.send({
      "errcode": "0",
      "errmsg": "ok",
      "data": [
        1
      ]
    })
  })

  // 班级分类列表
  app.post('/net/schooladmin/school-class/find-by-group', function(req, res) {
    res.send({
      "errcode": "0",
      "errmsg": "ok",
      "data": [{
          "gradeYear": 2017,
          "classCount": 3,
          "studentTotal": 14,
          "classList": [{
              "id": 1,
              "merchantId": 1,
              "schoolId": 1,
              "name": "一班",
              "gradeYear": 2017,
              "graduateYear": 2019,
              "created": 1507881715,
              "modified": 1508120631,
              "deleted": 0,
              "studentCount": 11
            },
            {
              "id": 2,
              "merchantId": 1,
              "schoolId": 1,
              "name": "二班",
              "gradeYear": 2017,
              "graduateYear": 2019,
              "created": 1507883554,
              "modified": 1508143046,
              "deleted": 0,
              "studentCount": 3
            },
            {
              "id": 3,
              "merchantId": 1,
              "schoolId": 1,
              "name": "class 3",
              "gradeYear": 2017,
              "graduateYear": 2019,
              "created": 1507883559,
              "modified": 1507883559,
              "deleted": 0,
              "studentCount": 0
            }
          ]
        },
        {
          "gradeYear": 2016,
          "classCount": 2,
          "studentTotal": 0,
          "classList": [{
              "id": 4,
              "merchantId": 1,
              "schoolId": 1,
              "name": "class1",
              "gradeYear": 2016,
              "graduateYear": 2018,
              "created": 1508136159,
              "modified": 1508136159,
              "deleted": 0,
              "studentCount": 0
            },
            {
              "id": 5,
              "merchantId": 1,
              "schoolId": 1,
              "name": "class2",
              "gradeYear": 2016,
              "graduateYear": 2018,
              "created": 1508136165,
              "modified": 1508136165,
              "deleted": 0,
              "studentCount": 0
            }
          ]
        }
      ]
    })
  })
}
